local common = require "common"

ClientSession = {}

-- Session状态
SessionStatus = 
{
	SS_NONE					= 0,	-- 未创建					
	SS_CREATED				= 1,	-- 刚创建
	SS_INGAME				= 2,	-- 已进入SS，游戏中
	SS_TRANSFERING			= 3,	-- 传送中
	SS_OFFLINEING			= 4,	-- 断线中
}

function ClientSession:New(o)
    o = o or {}	
	self.__index = self
	setmetatable(o, self)
	
	-- 下面写成员变量
	o.client_uid_ = 0
	o.pid_ = 0
	o.at_cs_ = nil
	o.account_idx_ = 0
	o.status_ = SessionStatus.SS_CREATED
	o.player_ = nil

    return o
end

function ClientSession:get_client_uid()
	return self.client_uid_
end

function ClientSession:set_account_idx(account_idx)
	self.account_idx_ = account_idx
end

function ClientSession:get_account_idx()
	return self.account_idx_
end

function ClientSession:set_pid(pid)
	self.pid_ = pid
end

function ClientSession:get_pid()
	return self.pid_
end

function ClientSession:get_status()
	return self.status_
end

function ClientSession:set_status(status)
	self.status_ = status
end

function ClientSession:get_player(player)
	return self.player_
end

function ClientSession:set_player(player)
	self.player_ = player
end

function ClientSession:Send()
	
end

return ClientSession